package com.xuan.friend.domain.question;

import com.baomidou.mybatisplus.annotation.*;
import com.xuan.common.core.domain.BaseEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;

/**
 * 题目表
 * @TableName question
 */
@EqualsAndHashCode(callSuper = true)
@TableName(value ="tb_question")
@Data
public class Question extends BaseEntity implements Serializable {
    /**
     * 题目id
     */
    @TableId(type = IdType.ASSIGN_ID)
    private Long questionId;

    /**
     * 题目名称
     */
    private String title;

    /**
     * 难度: 1-简单, 2-中等  3-困难
     */
    private Integer difficulty;

    /**
     * 题目内容/描述
     */
    private String content;

    /**
     * 时间限制
     */
    private Integer timeLimit;

    /**
     * 空间限制
     */
    private Integer spaceLimit;

    /**
     * 题目用例
     */
    private String questionCase;

    /**
     * 默认代码块/用户提交代码
     */
    private String defaultCode;

    /**
     * 代码运行的 main 函数
     */
    private String mainFunc;

    /**
     * 是否删除 
     */
    @TableLogic
    private Integer isDelete;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;
}